﻿using System.Security.Principal;
using System.Threading.Tasks;

namespace Sidvall.Security
{
    public interface IAuthorizationProvider
    {
        [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1024:UsePropertiesWhereAppropriate")]
        Task<ResourceItemCollection> GetSystemResourceItemsAsync();
        Task<ResourceItemCollection> GetResourceItemsAsync(IPrincipal principal);

        AuthorizeResult GetAuthorizeResult(IPrincipal principal, ResourceItemCollection items);
        Task<AuthorizeResult> GetAuthorizeResultAsync(IPrincipal principal, ResourceItemCollection items);
    }
}
